<?php
/**
 * +--------------------------------------------------------+
 * @Created by Phpstorm.
 * @Category ExceptionErrorService.php
 * @Depiction
 * @Author hwy <429208948@qq.com>
 * @Date 2022/3/23  16:56
 * +--------------------------------------------------------+
 */

namespace App\Services;

use App\Repositories\ExceptionErrorRepository;

class ExceptionErrorService extends BaseService
{
    protected $exceptionErrorRepository;

    public function __construct(ExceptionErrorRepository $exceptionErrorRepository)
    {
        $this->exceptionErrorRepository = $exceptionErrorRepository;
    }

    /**
     * @param $params
     * @return array
     * @Depiction 获取列表
     * @Author hwy <429208948@qq.com>
     * @Date 2022/3/23  19:48
     */
    public function getList($params)
    {
        $list = $this->exceptionErrorRepository->getList($params);

        return $list->toArray();
    }

    /**
     * @param $params
     * @return mixed
     * @Depiction
     * @Author hwy <429208948@qq.com>
     * @Date 2022/3/23  20:08
     */
    public function getInfo($params)
    {
        $data = $this->exceptionErrorRepository->getInfo($params);

        return $data;
    }

    /**
     * @param $exception
     * @return bool
     * @Depiction $exception
     * @Author hwy <429208948@qq.com>
     * @Date 2022/3/23  20:22
     */
    public function solve($exception): bool
    {
        $res = $this->exceptionErrorRepository->solve($exception);

        return $res;
    }


}
